package com.mq;

import com.entity.BaoxiaoEntity;
import com.entity.XinziEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jms.core.JmsMessagingTemplate;
import org.springframework.stereotype.Component;

@Component
public class PayslipProducer {


    @Autowired
    private JmsMessagingTemplate jmsMessagingTemplate;

    public void sendMsgToMq(XinziEntity xinziEntity){
        jmsMessagingTemplate.convertAndSend(" payslip",xinziEntity);
    }
}
